home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
asmutil
/
disasm.zip
/
KILCOLOR.DOC
< prev
next >
Wrap
Text File
|
1988-06-03
|
3KB
|
44 lines
This procedure is for those people who are using a black- and-white monitor
with the IBM Color/Graphics adapter. For most of us in this situation, the
reason was not necessarily because we wanted color graphics, but because the
monochrome adapter will work only with the IBM monochrome display. Anyone who
already owned a BW monitor, or who just didn't want to pay the price for the IBM
monochrome, had no choice but to purchase the color card. I wasn't as infuriated
by this as I thought I would be, since I realized that if I ever wanted graphics
in the future, I would have to get one anyway. The problem is that many of the
software packages assume that if you have the color adapter, you have a color
monitor connected to it. Therefore they automatically set mode to color,
causing a terrible display with unreadable text. Fortunately, many of the
packages ask you whether you want color or not, or at least provide a method of
changing the default. However, to defend myself from the sloppier programmers
who make their program almost useless by giving me an unreadable display, I
wrote the following program to disable color entirely. Even if the program sets
mode to color, the request is changed to black and write. The program is an
interrupt routine that intercepts and modifies calls to the set mode routine of
the video I/O package in ROM. When executed, it replaces the current video I/O
vector with itself. When the application program issues a video set mode
interrupt, the intercept routine receives it and changes any requests for color
to the equivalent BW mode. After modifying the mode, the program branches to
the original interrupt vector address, which it has saved. For set-modes to
black and white, or for functions other than set mode, the routine branches to
the original routine without changing anything. This technique causes no
permanent damage. The intercept routine goes away the next time the system is
booted. If and when you ever get a color monitor, just stop using the program.
It can be added to AUTOEXEC.BAT, so that it is always active. I have included
assembly language source for two different versions of the program, one for DOS
1.1 and another for 2.0. Logically they are identical, but the DOS 2.0 version
is slightly smaller, utilizing a new function call to get the current inter-
rupt vector. This function call didn't exist under 1.1, so it has to be done
manually. Microsoft recommends using this new function call. If you have 2.0,
use that version.
Note: the file kilcolor.com is the 1.1 version; kilcolr2 is the 2.0 version.
Wayne Sewell
3822 Hillsdale Lane
Garland, TX 75042
Source STA123
P.S. This appeared in the *.* column of last month's PC World.